<template>
  <el-container>
    <!-- 头部区域 -->
    <el-header>
      <div class="center">
        <img src alt />
        <span>学会联盟</span>
      </div>
      <el-button type="info" @click="logout">退出</el-button>
    </el-header>
    <!-- 页面主题区域 -->
    <el-container>
      <!-- 侧边栏 -->
      <el-aside width="200px">
        <!-- //侧边栏菜单区域  -->
        <el-menu
        el-menu :default-active="activeIndex"
           class="el-menu-vertical-demo"
      @open="handleOpen"
      @close="handleClose"
         router
        

          background-color="#545c64"
          text-color="#fff"
          active-text-color="#ffd04b"

        >
          <!-- 一级菜单 -->
           <el-submenu index="1">
        <template slot="title">
          <i class="el-icon-location"></i>
          <span>导航一</span>
        </template>
        <el-menu-item-group>
          
          <el-menu-item index="1-1">选项1</el-menu-item>
          <el-menu-item index="1-2">选项2</el-menu-item>
        </el-menu-item-group>
       
       
      </el-submenu>
          <el-menu-item index="index">学生任务</el-menu-item>
          <el-menu-item index="3">聊天室</el-menu-item>
          <el-menu-item index="4"
            ><a href="../../static/音乐播放器111.html" target="_blank"
              >播放器</a
            ></el-menu-item
          >
        </el-menu>
      </el-aside>
      <!-- 右侧内容主体 -->

      <el-main>
        
         <div class="demo-image__lazy">
  <el-image v-for="url in urls" :key="url" :src="url" lazy></el-image>
</div>
        
      </el-main>
    </el-container>
  </el-container>
</template>

<script>
 export default {
    data() {
      return {
        urls: [
          'https://fuss10.elemecdn.com/a/3f/3302e58f9a181d2509f3dc0fa68b0jpeg.jpeg',
          'https://fuss10.elemecdn.com/1/34/19aa98b1fcb2781c4fba33d850549jpeg.jpeg',
          'https://fuss10.elemecdn.com/0/6f/e35ff375812e6b0020b6b4e8f9583jpeg.jpeg',
          'https://fuss10.elemecdn.com/9/bb/e27858e973f5d7d3904835f46abbdjpeg.jpeg',
          'https://fuss10.elemecdn.com/d/e6/c4d93a3805b3ce3f323f7974e6f78jpeg.jpeg',
          'https://fuss10.elemecdn.com/3/28/bbf893f792f03a54408b3b7a7ebf0jpeg.jpeg',
          'https://fuss10.elemecdn.com/2/11/6535bcfb26e4c79b48ddde44f4b6fjpeg.jpeg'
        ]
      }
    },
    methods: {
      handleOpen(key, keyPath) {
        console.log(key, keyPath);
      },
      handleClose(key, keyPath) {
        console.log(key, keyPath);
      }
    }
  }
</script>

<style>
.el-container {
  height: 100vh;
}
.el-header {
  background-color: #b3c0d1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #fff;
  font-size: 20px;

  /*    
    text-align: center;
    line-height: 60px; */
}

.el-aside {
  background-color: #545c64;

  text-align: center;
  line-height: 200px;
}

.el-main {
  background-color: #e9eef3;

  text-align: center;
  line-height: 160px;
}

.center {
  display: flex;
  align-items: center;
}
</style>
